import request from '@/utils/request'
export function createTaskForId(data){
    return request({
        url:"/xhs/crawl_note_by_id",
        method:"get",
        params:{
            data
        }
    })
}
export function createTasksForKeyword(data){
    return request({
        url:"/xhs/crawl_notes_by_keyword",
        method:"post",
        data: data
    })
}export function createTasksForPosterId(data){
    return request({
        url:"/xhs/crawl_notes_by_poster_id",
        method:"post",
        data: data
    })
}

export function getIndexData(index){
    return request({
        url:'/xhs/getHomePage',
        method:'get',
        params:{
            index
        }
    })
}
export function getNoteById(noteId){
    return request({
        url:'/xhs/getNoteById',
        method:'get',
        params:{
           noteId
        }
    })
}
export function getNoteByKeyword(keyword){
    return request({
        url:'/xhs/getSearchResultByKeyword',
        method:'get',
        params:{
            keyword
        }
    })
}
export function getNoteByPosterId(posterId){
    return request({
        url:'/xhs/getNotesByPosterId',
        method:'get',
        params:{
            posterId
        }
    })
}

